# Maintainer: Justin Davis (juster) <jrcd83@gmail.com>
# $Id: PKGBUILD 86649 2013-03-20 22:41:14Z eric $

pkgname=cpanminus
pkgver=1.6008
pkgrel=1
pkgdesc='Get, unpack, build and install modules from CPAN.'
arch=(any)
license=(PerlArtistic GPL)
options=(!emptydirs)
depends=(perl)
provides=("perl-app-cpanminus=$pkgver")
url="https://metacpan.org/release/App-cpanminus"
source=("http://search.cpan.org/CPAN/authors/id/M/MI/MIYAGAWA/App-cpanminus-$pkgver.tar.gz")
md5sums=('5c0e9008300490529aadff772a45f152')

build()
(
  cd App-cpanminus-$pkgver
  export PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps
  unset PERL5LIB PERL_MM_OPT
  /usr/bin/perl Makefile.PL
  make
)

check()
(
  cd App-cpanminus-$pkgver
  export PERL_MM_USE_DEFAULT=1
  unset PERL5LIB
  make test
)

package()
(
  cd App-cpanminus-$pkgver
  make install INSTALLDIRS=vendor DESTDIR="$pkgdir"
)

# Local Variables:
# mode: shell-script
# sh-basic-offset: 2
# End:
# vim:set ts=2 sw=2 et:
